package lab02.test25;

import java.util.Scanner;

/**
 * Created by Administrator on 2017/11/21.
 */
public class ExceptionTest {  public static void main(String[] args) {
    Scanner scanner = new Scanner(System.in);
    System.out.println("请输入被除数：");
    int b=scanner.nextInt();
    System.out.println("请输入除数：");
    int c=scanner.nextInt();
    try {
        System.out.println(b+"/"+c+"="+b/c);
    }catch (ArithmeticException e){
        System.out.println("除数为0！！！");
    }

}
}
